<template>
  <div class="header">
    <div class="header-title">{{ appName }}</div>
  </div>
</template>

<script setup lang="ts" name="header">
import { ref } from "vue";
import { useRouter } from "vue-router";
const router = useRouter();

const appName = ref(import.meta.env.VITE_APP_API_NAME);

const handleLoginOut = () => {
  localStorage.setItem("userToken", "");
  // 重定向到主页
  router.push("/");
};
</script>
